<?php
/**
 * 商户端---商品分类管理
 */

namespace app\store\controllers\goods;

use App\store\controllers\StoreBaseController;

class CategoryController extends StoreBaseController
{

    private  $thisClass = 'Category';

    /**
     * 商品分类
     * @return void
     */
    public function getLists()
    {
        //获取数据
        $data = self::getStoreData($this->thisClass, 'Lists');

        return successJson('ok', $data);
    }

    /**
     * 添加/编辑分类
     * @return void
     */
    public function categoryModify()
    {
        $categoryId = request()->input('c_id', 0);

        //获取数据
        $data = self::getStoreData($this->thisClass, 'categoryModify');

        return successJson('ok', $data);

    }

    /**
     * 删除分类
     * @return void
     */
    public function categoryDelete()
    {
        $categoryId = request()->input('c_id', 0);

        //获取数据
        $data = self::getStoreData($this->thisClass, 'categoryDelete');

        return successJson('ok', $data);
    }

    /**
     * 分类信息
     * @return void
     */
    public function categoryDetails()
    {
        $categoryId = request()->input('c_id', 0);

        //获取数据
        $data = self::getStoreData($this->thisClass, 'categoryDetails');

        return successJson('ok', $data);

    }



}
